<!--
  Generated template for the DetailsPage page.

  See http://ionicframework.com/docs/components/#navigation for more info on
  Ionic pages and navigation.
-->
<ion-header>

    <ion-navbar>
        <ion-title>{{question?.ContentTitle}}</ion-title>
    </ion-navbar>

</ion-header>


<ion-content>
    <ion-card>
        <ion-card-content>
            {{question?.Content}}
            <p>{{question?.LikeCount}}&nbsp;个人关注&nbsp;&nbsp;{{question?.CommentCount}}&nbsp;个回答</p>
            <button (click)="goAnwser()" ion-button small [disabled]="isMyQuestion">
              <ion-icon name ="add"></ion-icon>&nbsp;回答
            </button>&nbsp;
            <button (click)="saveFavourite()" ion-button small color="secondary">
              <ion-icon name ="add"></ion-icon>&nbsp;{{isFavourite ? '取消关注' : '关注'}}
            </button>
        </ion-card-content>
    </ion-card>
    <ion-card *ngFor="let item of anwsers">
        <ion-item>
            <ion-avatar item-start>
                <img [alt]="item?.HeadFace">
            </ion-avatar>
            <p>
                {{item.UserNickName}}
            </p>
        </ion-item>
        <ion-card-content>
            <p>{{item?.Content}}</p>
            <p class="answer_date">{{item?.CreateDateTime}}</p>
        </ion-card-content>
    </ion-card>
</ion-content>